///*
// * To change this template, choose Tools | Templates
// * and open the template in the editor.
// */
//package wsgroovy;
//
//import groovy.lang.GroovyClassLoader;
//import groovyx.net.ws.WSClient;
//import java.io.File;
//import java.io.IOException;
//import java.util.logging.Level;
//import java.util.logging.Logger;
//import org.codehaus.groovy.control.CompilationFailedException;
//import ws.FornecedorVetor;
//
///**
// *
// * @author André
// */
//public class ManagerWebService implements IManagerWebService {
//
//    private WSClient proxy;
//    private static ManagerWebService instance;
//    private IManagerWebService mgr;
//    private FornecedorVetor fornecedorVetor;
//
//    public static ManagerWebService getInstance() {
//        if (instance == null) {
//            instance = new ManagerWebService();
//        }
//        return instance;
//    }
//
//    private ManagerWebService() {
//        try {
//            GroovyClassLoader groovyClassLoader = new GroovyClassLoader();
//            Class classeProxy = groovyClassLoader.parseClass(
//                    //new File("./src/java/persistencia/conexao/Conexao.groovy"));
//                    new File("E:/NetbeansProjects/TCC/GrailsTCC/src/java/wsgroovy/ManagerWebService.groovy"));
//            mgr = (IManagerWebService) classeProxy.newInstance();
//            proxy = mgr.getProxy();
//            if (proxy == null) {
//                System.out.println("Proxy eh null");
//            } else {
//                System.out.println("Proxy NAO eh null");
//            }
//        } catch (InstantiationException ex) {
//            Logger.getLogger(ManagerWebService.class.getName()).log(Level.SEVERE, null, ex);
//        } catch (IllegalAccessException ex) {
//            Logger.getLogger(ManagerWebService.class.getName()).log(Level.SEVERE, null, ex);
//        } catch (CompilationFailedException ex) {
//            Logger.getLogger(ManagerWebService.class.getName()).log(Level.SEVERE, null, ex);
//        } catch (IOException ex) {
//            Logger.getLogger(ManagerWebService.class.getName()).log(Level.SEVERE, null, ex);
//        }
//    }
//
//    public WSClient getProxy() {
//        return proxy;
//    }
//
//    public FornecedorVetor getFornecedorVetor() {
//        return fornecedorVetor;
//    }
//
//    public void setFornecedorVetor(FornecedorVetor fornecedorVetor) {
//        this.fornecedorVetor = fornecedorVetor;
//    }
//}
